NIGHT SHIFT 1.0.0
BioInfo AI / BioInfo Solutions, LLC

Keep your place while your Mac works.

A short pause should not require you to hunt for your screen. Night Shift saves
your Mac's two original wall-power idle timers, sets both to Never, and gives
you a simple restore command. Use your monitor's power button when you are
ready for darkness. Automatic locking is a separate macOS setup step.

QUICK START

1. Extract the whole ZIP into a local folder. Keep the files together.
2. Read SETUP-AND-VERIFY.txt and configure automatic locking in System Settings.
3. Open Terminal. Type `bash ` (with a trailing space), drag night-shift.sh from
   Finder into Terminal, add ` --dry-run`, and press Return.
4. Repeat with ` --apply`. macOS may request an administrator password. Terminal
   displays no password characters. The script never receives or saves it.
5. Run ` --status`, then complete the screen-saver/lock check in the setup file.

The optional Night Shift.command menu performs the same operations. Depending
on macOS download protections, Finder may require explicit permission to open
it. Use the Terminal instructions above if double-clicking is unavailable;
there is no need to turn off Gatekeeper or change global security settings.

COMMANDS (from the extracted folder)

  bash night-shift.sh --dry-run
  bash night-shift.sh --apply
  bash night-shift.sh --status
  bash night-shift.sh --restore
  bash night-shift.sh --help

Run as your normal user. Do not prefix the whole script with sudo. Only the
specific power-setting command requests administrator authentication.

EXACT SCOPE

The apply command is: sudo /usr/bin/pmset -c displaysleep 0 sleep 0
0 means Never. -c targets wall/charger power only. The Mac remains able to sleep
when you explicitly request sleep. Battery timers, disk sleep, screen-saver
settings, passwords, FileVault, network settings and other preferences are
outside this script's changes. Laptop lid behavior is unchanged.

No downloads, telemetry, account registration, Python, external packages,
activity spoofing or password storage. Bash 3.2 is sufficient.

The screen saver may replace the work view, and macOS or a monitor may turn off
the display while locked. This package does not promise a permanently glowing
lock screen. Configure and test locking; do not weaken your password settings
to make a display stay lit. A monitor's own eco/sleep controls remain separate.

RESTORE AND SAVED STATE

The first authorized apply saves only the two original AC timers, this Mac's
local hardware identifier and a timestamp in:

  ~/Library/Application Support/BioInfo AI/Night Shift/baseline.txt

The identifier never leaves this Mac. The saved baseline belongs to your user,
has private permissions, and is data: it is never sourced or evaluated as code.
Apply and restore retain the first baseline across reruns. A baseline copied
from another Mac is refused. Restore changes only those two saved timers.

If those timers were already 0 before your first apply, restore correctly
restores 0; it cannot recover settings from before this product was installed.
Other users of this same Mac should coordinate power settings: AC timers are
system settings, while the baseline is per user.

RECOVERY

An interrupted run can leave an operation.lock directory. First make sure no
Night Shift operation is running in another Terminal. Then use Finder's
Go -> Go to Folder to open the saved-state folder above and remove only the
empty operation.lock directory. Keep baseline.txt. Run --status before retrying.

Never edit the baseline to insert commands. Unexpected fields or invalid
permissions stop the script. If permissions were accidentally changed, your
own saved baseline should be chmod 600 and its Night Shift folder chmod 700.
Ask BioInfo AI for help before discarding a baseline or changing its values.
There is no automatic reset: retaining the original snapshot protects undo.

COMPATIBILITY AND VERIFICATION

Built for macOS Macs connected to wall power with administrator authorization.
Its read-only parser was exercised against the live power-settings output on
the development Mac. Apply/restore, cancelled authorization, repeated apply,
unrelated-setting preservation, invalid baseline and failure paths were tested
using isolated mock commands. Hardware settings were not changed in that test.
macOS versions and hardware configurations were not comprehensively certified.

Managed-device policies can override timers. Explicit sleep, closed laptop
lids, crashes, power loss, monitor controls and operating-system lock behavior
can still interrupt a session. A successful timer change does not keep a job
alive through those events.

ENERGY AND COMFORT

An illuminated display uses power and accumulates panel/backlight operating
hours. Lower its brightness to a comfortable level. At bedtime, lock first
(Control-Command-Q), then switch the monitor off. Your Mac can continue working
without lighting the room. On many Windows keyboards the Windows key acts as
Command. A monitor left plugged in and switched off normally uses a small
standby/off draw; consult your exact monitor's specifications.

Support: use the BioInfo AI contact details on bioinfo-ai-studio-wine.vercel.app.
License and support scope: see LICENSE.txt. Version: 1.0.0.
